{
 "metadata": {
  "language_info": {
   "codemirror_mode": {
    "name": "ipython",
    "version": 3
   },
   "file_extension": ".py",
   "mimetype": "text/x-python",
   "name": "python",
   "nbconvert_exporter": "python",
   "pygments_lexer": "ipython3",
   "version": "3.9.6"
  },
  "orig_nbformat": 4,
  "kernelspec": {
   "name": "python3",
   "display_name": "Python 3.9.6 64-bit"
  },
  "interpreter": {
   "hash": "e4d85d63baa40a9854e1e91e14fde8d7f9b9a564a40f3bc91b58b47abf2bd79f"
  }
 },
 "nbformat": 4,
 "nbformat_minor": 2,
 "cells": [
  {
   "cell_type": "code",
   "execution_count": 1,
   "metadata": {},
   "outputs": [
    {
     "output_type": "error",
     "ename": "ImportError",
     "evalue": "cannot import name 'Bar' from 'pyecharts' (C:\\Users\\songzhao\\AppData\\Local\\Programs\\Python\\Python39\\lib\\site-packages\\pyecharts\\__init__.py)",
     "traceback": [
      "\u001b[1;31m---------------------------------------------------------------------------\u001b[0m",
      "\u001b[1;31mImportError\u001b[0m                               Traceback (most recent call last)",
      "\u001b[1;32m~\\AppData\\Local\\Temp/ipykernel_56752/3326095335.py\u001b[0m in \u001b[0;36m<module>\u001b[1;34m\u001b[0m\n\u001b[1;32m----> 1\u001b[1;33m \u001b[1;32mfrom\u001b[0m \u001b[0mpyecharts\u001b[0m \u001b[1;32mimport\u001b[0m \u001b[0mBar\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0m\u001b[0;32m      2\u001b[0m \u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m      3\u001b[0m \u001b[0mbar\u001b[0m \u001b[1;33m=\u001b[0m \u001b[0mBar\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;34m'我的第一个图表'\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;34m'这里是副标题'\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m      4\u001b[0m \u001b[0mbar\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0muse_theme\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;34m'dark'\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n\u001b[0;32m      5\u001b[0m \u001b[0mbar\u001b[0m\u001b[1;33m.\u001b[0m\u001b[0madd\u001b[0m\u001b[1;33m(\u001b[0m\u001b[1;34m'服装'\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m[\u001b[0m\u001b[1;34m\"衬衫\"\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;34m\"羊毛衫\"\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;34m\"雪纺衫\"\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;34m\"裤子\"\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;34m\"高跟鞋\"\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;34m\"袜子\"\u001b[0m\u001b[1;33m]\u001b[0m\u001b[1;33m,\u001b[0m\u001b[1;33m[\u001b[0m\u001b[1;36m5\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;36m20\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;36m36\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;36m10\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;36m75\u001b[0m\u001b[1;33m,\u001b[0m \u001b[1;36m90\u001b[0m\u001b[1;33m]\u001b[0m\u001b[1;33m)\u001b[0m\u001b[1;33m\u001b[0m\u001b[1;33m\u001b[0m\u001b[0m\n",
      "\u001b[1;31mImportError\u001b[0m: cannot import name 'Bar' from 'pyecharts' (C:\\Users\\songzhao\\AppData\\Local\\Programs\\Python\\Python39\\lib\\site-packages\\pyecharts\\__init__.py)"
     ]
    }
   ],
   "source": [
    "from pyecharts import Bar\n",
    " \n",
    "bar = Bar('我的第一个图表', '这里是副标题')\n",
    "bar.use_theme('dark')\n",
    "bar.add('服装',[\"衬衫\", \"羊毛衫\", \"雪纺衫\", \"裤子\", \"高跟鞋\", \"袜子\"],[5, 20, 36, 10, 75, 90])\n",
    " \n",
    "bar.render(r'firstEchart.html')"
   ]
  },
  {
   "cell_type": "code",
   "execution_count": null,
   "metadata": {},
   "outputs": [],
   "source": []
  }
 ]
}